feat(worker): 网页终端增加 favicon(暗色终端主题图标 bn + >_)#313
Merged
Conversation
每个会话终端链接打开的网页终端页(getTerminalHtml)此前无 favicon。 - 新增 src/utils/terminal-favicon.ts,把暗色终端图标内联为 data URI(64x64 PNG) - worker 终端页是直出 HTML、不经静态资源服务,故用 data URI 而非外链文件 - v3 live 终端 iframe 同一页面,favicon 一并覆盖;replay 为 srcdoc iframe 不显示 tab 图标,无需处理
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
改动
给网页终端(每个会话终端链接打开的页面,
worker.ts的getTerminalHtml)增加 favicon——暗色终端主题图标(bn 标 +>_提示符)。src/utils/terminal-favicon.ts,把图标内联为 data URI(64×64 PNG)res.end(getTerminalHtml(...))直出 HTML、不经静态资源服务,故用 data URI 而非外链文件<head>增加<link rel="icon">验证
pnpm build通过;确认编译后dist/worker.js含 favicon link 与terminal-favicon引用、dist/utils/terminal-favicon.js已生成